package com.kuang.gulimall.product.vo;

import com.kuang.gulimall.product.entity.SkuImagesEntity;
import com.kuang.gulimall.product.entity.SkuInfoEntity;
import com.kuang.gulimall.product.entity.SpuInfoDescEntity;
import lombok.Data;

import java.util.List;

@Data
public class SkuItemVo {
    //1，sku基本信息获取  pms_sku_info
    SkuInfoEntity skuInfoEntity;
    boolean hasStock = true;

    //2，sku图片信息 pms_sku_images
    List<SkuImagesEntity> images;

    //3，获取spu的销售信息组合
    List<SkuItemSaleAttrVo> saleAttr;

    //4，获取spu的商品介绍
    SpuInfoDescEntity desp;

    //5，获取spu的规格参数信息
    List<SpuItemAttrGroupVo> groupAttrs;

    //当前商品秒杀的优惠信息
    SeckillInfoVo seckillInfo;


    @Data
    public static class SkuItemSaleAttrVo{
        private Long attrId;
        private String attrName;
        private List<AttrValueWithSkuIdVo> attrValues;
    }

    @Data
    public static class SpuItemAttrGroupVo{
        private String groupName;
        private List<SpuBaseAttrVo> attrs;
    }

    @Data
    public static class SpuBaseAttrVo{
        private String attrName;
        private String attrValue;
    }



}
